package com.scau.wrongtitle.repository;

import com.scau.wrongtitle.domin.QuestionAnswer;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import java.util.List;

public interface QuestionAnswerRepository extends JpaRepository<QuestionAnswer, Long> {

    @Query(value = "select questionAnswer from QuestionAnswer where questionId = :id")
    List<String> findAllByQuestionId(@Param("id")long qid);
}
